From: Matthieu Gallien Date: Thu, 15 May 2025 10:04:43 +0000 (+0200) Subject: fix(delete): always print warnings when file deletions fail X-Git-Tag: archive/raspbian/3.16.7-1_deb13u1+rpi1^2~13^2~1^2~37^2~4 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/success/%22http:/www.example.com/cgi/success?a=commitdiff_plain;h=4bd1ed6c15765860ce9d2195bf90f44e9a585267;p=nextcloud-desktop.git fix(delete): always print warnings when file deletions fail Signed-off-by: Matthieu Gallien --- diff --git a/src/libsync/propagatorjobs.cpp b/src/libsync/propagatorjobs.cpp index 6711685a3..072ccbfd7 100644 --- a/src/libsync/propagatorjobs.cpp +++ b/src/libsync/propagatorjobs.cpp @@ -110,6 +110,7 @@ void PropagateLocalRemove::start() if (_moveToTrash && propagator()->syncOptions()._vfs->mode() != OCC::Vfs::WindowsCfApi) { if ((QDir(filename).exists() || FileSystem::fileExists(filename)) && !FileSystem::moveToTrash(filename, &removeError)) { + qCWarning(lcPropagateLocalRemove()) << "move to trash failed" << filename << removeError; done(SyncFileItem::NormalError, tr("Temporary error when removing local item removed from server."), ErrorCategory::GenericError); return; } @@ -127,6 +128,7 @@ void PropagateLocalRemove::start() const auto parentPermissionsHandler = FileSystem::FilePermissionsRestore{parentFolderPath, FileSystem::FolderPermissions::ReadWrite}; if (!FileSystem::remove(filename, &removeError)) { + qCWarning(lcPropagateLocalRemove()) << "remove failed" << filename << removeError; done(SyncFileItem::NormalError, tr("Temporary error when removing local item removed from server."), ErrorCategory::GenericError); return; }